﻿using TouchTable.Debug;
using UnityEngine;

namespace UnityTouchTable.Runtime
{
    /// <summary>
    /// 默认日志类
    /// </summary>
    public class DefaultLogHelper : ILogHelper
    {
        /// <summary>
        /// 信息
        /// </summary>
        /// <param name="info">信息</param>
        public void Info(object info)
        {
            Debug.Log(string.Format("<color=#888888>Info:{0}</color>", info.ToString()));
        }

        /// <summary>
        /// 日志
        /// </summary>
        /// <param name="log">日志</param>
        public void Log(object log)
        {
            Debug.Log(string.Format("Log:{0}", log.ToString()));
        }

        /// <summary>
        /// 警告
        /// </summary>
        /// <param name="warning">警告</param>
        public void Warning(object warning)
        {
            Debug.LogWarning(string.Format("Warning:{0}", warning.ToString()));
        }

        /// <summary>
        /// 错误
        /// </summary>
        /// <param name="error">错误</param>
        public void Error(object error)
        {
            Debug.LogError(string.Format("Error:{0}", error.ToString()));
        }
    }
}